home *** CD-ROM | disk | FTP | other *** search
/ C/C++ Interactive Reference Guide / C-C++ Interactive Reference Guide.iso / c_ref / csource5 / 310_01 / check.st < prev    next >
Text File  |  1990-04-20  |  178b  |  16 lines

  1. Class CheckBook
  2. | balance |
  3. [
  4.     new
  5.         balance <- 0
  6. |
  7.     + amount
  8.         balance <- balance + amount.
  9.         ^ balance
  10. |
  11.     - amount
  12.         balance <- balance - amount.
  13.         ^ balance
  14. ]
  15.  
  16.